package com.dj.springcloud.service.impl;




import com.dj.springcloud.dao.PaymentDao;
import com.dj.springcloud.entities.Payment;
import com.dj.springcloud.service.PaymentService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @auther Dev_J
 * @date 2020-12-10 22:33
 */
@Service
public class PaymentServiceImpl implements PaymentService {
//    @Autowired是spring的 @Resource是Java自带的

    @Resource
    private PaymentDao paymentDao;
    @Override
    public int create(Payment payment){
        return paymentDao.create(payment);
    }

    @Override
    public  Payment getPaymentById(Long id){
        return paymentDao.getPaymentById(id);
    }

}
